<template>
	<div class="header g-font-f1">
		<img class="back" src="~assets/images/back.png" @click="back"></img>
    <div>
      <slot></slot>
    </div>
	</div>
</template>

<script>

export default {
  data () {
    return {
    }
  },
  props: {
    title: {
      type: String
    }
  },
  methods: {
    back () {
      this.$route.name == 'Index'
        ? window.location.href = 'gtjanormal://goback'
        : this.$router.go(-1)
    }
  }
}

</script>

<style lang="less" scoped>
.header{
  font-size:0.18rem;
  position: absolute;
  top: 0;
  display: flex;
  z-index: 10000000;
  justify-content: space-around;
  height:0.44rem;
  line-height: 0.44rem;
  width: 100%;
  background-color: white;
  box-shadow: 0 2px 0.05rem 0 rgba(0,0,0,0.1);
  .back{
    position:absolute;
    left:0;
    height:0.20rem;
    padding:0.12rem 0.15rem;
  }
}
</style>
